﻿@model IEnumerable<CoffeeTeaTrading.Repository.Models.Order>

@{
    ViewBag.Title = "Index";
    Layout = "~/Views/Shared/_Layout.cshtml";
}

<h2>Index</h2>

<table>
    <tr>
        <th></th>
        <th>
            CustomerId
        </th>
        <th>
            Status
        </th>
        <th>
            OrderDateStart
        </th>
        <th>
            OrderDateEnd
        </th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.ActionLink("Edit", "Edit", new { id=item.Id }) |
            @Html.ActionLink("Details", "Details", new { id=item.Id }) |
            @Html.ActionLink("Delete", "Delete", new { id=item.Id })
        </td>
        <td>
            @item.CustomerId
        </td>
        <td>
            @item.Status
        </td>
        <td>
            @String.Format("{0:g}", item.OrderDateStart)
        </td>
        <td>
            @String.Format("{0:g}", item.OrderDateEnd)
        </td>
    </tr>
}

</table>

